package com.baselibrary.test.ui;

import android.os.Bundle;
import android.view.View;
import android.widget.Button;
import android.widget.ImageView;

import com.baselibrary.libs.Utils.Toast.UtilsToast;
import com.baselibrary.libs.View.bar.initAction_Bar;
import com.baselibrary.libs.base.baseActivity.BaseActivity;
import com.baselibrary.test.R;
import com.baselibrary.test.app.AppContext;

public class Main14Activity extends BaseActivity implements View.OnClickListener {

    private ImageView iv;
    private Button callback;
    private Button call;
    private initAction_Bar action_bar;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
    }

    @Override
    public int getlayouXML() {
        return R.layout.activity_main14;
    }

    @Override
    public void initP() {

    }

    @Override
    public void initView() {

        iv = (ImageView) findViewById(R.id.iv);
        iv.setOnClickListener(this);
        callback = (Button) findViewById(R.id.callback);
        callback.setOnClickListener(this);
        call = (Button) findViewById(R.id.call);
        call.setOnClickListener(this);
        action_bar = (initAction_Bar) findViewById(R.id.action_bar);
        action_bar.set_Title("大图片上面有小按钮");
    }

    @Override
    public void initData() {

    }

    @Override
    public void initListener() {

    }

    @Override
    public void onClick(View v) {
        switch (v.getId()) {
            case R.id.callback:
                finish();
                break;
            case R.id.call:
                UtilsToast.showToast(AppContext.getApplication(),"我点了赞");
                break;
        }
    }
}
